package com.zhijian.warehouse.manage.dao;

import com.zhijian.warehouse.manage.entity.po.StoreAllotRecordProduct;
import com.zhijian.warehouse.manage.entity.vo.request.StoreAllotRecordProductSearchVo;
import com.zhijian.warehouse.manage.entity.vo.response.StoreAllotRecordProductVo;
import java.util.List;
import org.apache.ibatis.annotations.Param;

public interface StoreAllotRecordProductMapper {
    int deleteByPrimaryKey(Long id);

    int insert(StoreAllotRecordProduct record);

    int insertSelective(StoreAllotRecordProduct record);

    StoreAllotRecordProduct selectByPrimaryKey(Long id);

    int updateByPrimaryKeySelective(StoreAllotRecordProduct record);

    int updateByPrimaryKey(StoreAllotRecordProduct record);

    /**
     * 查询总数
     *
     * @param storeAllotRecordProductSearchVo
     * @return
     */
    int count(StoreAllotRecordProductSearchVo storeAllotRecordProductSearchVo);

    /**
     * 查询列表
     *
     * @param storeAllotRecordProductSearchVo
     * @return
     */
    List<StoreAllotRecordProductVo> selectList(StoreAllotRecordProductSearchVo storeAllotRecordProductSearchVo);

    /**
     * 查询单个
     *
     * @param storeAllotRecordProductSearchVo
     * @return
     */
    StoreAllotRecordProductVo selectOne(StoreAllotRecordProductSearchVo storeAllotRecordProductSearchVo);

    /**
     * 根据ID查询vo
     *
     * @param id
     * @return
     */
    StoreAllotRecordProductVo selectVoById(Long id);

    /**
     * 批量删除
     *
     * @param idList
     * @return
     */
    void deleteByIdList(@Param("idList") List<Long> idList);

    /**
     * 动态删除
     *
     * @param storeAllotRecordProductSearchVo
     * @return
     */
    void deleteByCondition(StoreAllotRecordProductSearchVo storeAllotRecordProductSearchVo);

    /**
     * 批量新增
     *
     * @param entities
     * @return
     */
    int insertBatch(@Param("entities") List<StoreAllotRecordProduct> entities);

    /**
     * 根据StoreAllotRecordId查询列表
     *
     * @param storeAllotRecordId
     * @return
     */
    List<StoreAllotRecordProductVo> selectListByStoreAllotRecordId(Long storeAllotRecordId);

    /**
     * 根据ProductId查询列表
     *
     * @param productId
     * @return
     */
    List<StoreAllotRecordProductVo> selectListByProductId(Long productId);

    /**
     * 根据WarehouseId查询列表
     *
     * @param warehouseOutId
     * @return
     */
    List<StoreAllotRecordProductVo> selectListByWarehouseId(Long warehouseOutId);

    /**
     * 根据WarehouseLocationId查询列表
     *
     * @param warehouseLocationOutId
     * @return
     */
    List<StoreAllotRecordProductVo> selectListByWarehouseLocationId(Long warehouseLocationOutId);
}
